In recent years, with the rapid development of mobile communication technologies, various hand-held terminal devices such as mobile phones and Personal Digital Assistants (PDAs) have become indispensable electronic devices in daily life. When a web page is browsed using a browser on a hand-held terminal device, an input box is usually displayed in the web page to receive information input by a user. When the user clicks a certain input box in the web page, an input method interface usually pops up from the bottom of the screen of the hand-held terminal device to allow the user to input information as required by the input box. If the position of the input box displayed on the web page as browsed, i.e., the current position of the input box, is on the lower part of the screen of the hand-held terminal device, the input box may be covered by the popped up input method interface in the browser, resulting in that the user cannot review the information inputted in the input box. Therefore, it is necessary to relocate the input box to a reasonable target position, so that the input box is visible to the user when the input method interface pops up.
In an existing method based on a system browser, after an input box is clicked at its current position, a control such as an input method interface like a soft keyboard is created at the position of the input box, and this method is mainly applicable to a system self-drawn input method. However, if the current position of the input box is at the bottom of the screen of the hand-held terminal device, the input box still cannot be displayed in a visible region, thus interfering with the inputting by the user; moreover, this method does not support the attribute of CONTENTEDITABLE in Hyper Text Mark-up Language (HTML).
In order to solve the above problem, a method for designating a target position of an input box based on an estimated value has been put forward in the prior art, where, when an input method interface pops up from the bottom of the screen, it is roughly determined whether the input method interface will cover the input box by determining the position of a cursor of the input box at the current position in the screen of the hand-held terminal device; and if so, the web page as browsed is moved upward by a preset distance, so that the input box is visible to the user.
This method solves the problem of the above method based on the system browser, and is mainly applicable to a self-drawn input method. However, there still exist the following disadvantages that: in this method, an approximate position of the input box in the screen is estimated, and then the web page as browsed is moved accordingly, that is, if the current position of the input box is at the bottom of the screen of the hand-held terminal device, a blank region exists below the designated target position of the input box due to the upward movement of the web page as browsed, as a result, user experience will be severely degraded; this method cannot be well adapted to screens with various resolutions; moreover, if a verification code exists above the current position of the input box, this method may cause the verification code to be beyond the screen and invisible after the input box is relocated. As a result, in fact, it is difficult to give a reasonable target position of the input box so that the verification code is visible to the user.